﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class paginas_Control_MenuPrincipal : System.Web.UI.UserControl
{
    protected void Page_Load(object sender, EventArgs e)
    {
        this.liAdminMenu.Visible = ApplicationEnvironment.Instance.User.EhAdmin;

        if (Session["AppSession"].Equals("Principal"))
        {
            this.hrefDefaultMenu.Attributes["href"] = string.Empty;
            this.hrefDefaultMenu.Attributes["class"] = "active";
            return;
        }
        if (Session["AppSession"].Equals("Rel"))
        {
            this.hrefRelMenu.Attributes["href"] = string.Empty;
            this.hrefRelMenu.Attributes["class"] = "active";
            return;
        }

        if (Session["AppSession"].Equals("Admin"))
        {
            this.hrefAdminMenu.Attributes["href"] = string.Empty;
            this.hrefAdminMenu.Attributes["class"] = "active";
            return;
        }
    }
}